package com.leeon.generics;

public class Wildcards {

	@SuppressWarnings({ "rawtypes", "unused" })
	static void rawArgs(Holder holder,Object arg){
		holder.set(arg);
		Object obj = holder.get();
	}
	
	static void unboundedArg(Holder<?> holder,Object arg){
		//holder.set(arg);
	}
	
	static <T> T exact1(Holder<T> holder){
		return holder.get();
	}
	
	static <T> T exact2(Holder<T> holder,T arg){
		holder.set(arg);
		return holder.get();
	}
	
	static <T> T wildSubtype(Holder<? extends T> holder,T arg){
		//holder.set(arg);
		return holder.get();
	}
	
	static <T> void wildSuperType(Holder<? super T> holder,T arg){
		holder.set(arg);
		//T t = holder.get();
	}
}
